package com.s4j.struts.biz.model;

import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity
@Table(name="biz_li_treathis")
public class BizLiTreathis {
	private Long treatId;	
	private PatientDoc patient;
	private Integer isyg;
	private Integer isbg;
	private Integer iszs;
	private Integer jieyan;
	private Integer jiejiu;
	private Integer kztz;
	private String other;
	
	private List<BizLiYgwm> ygwm;	
	
	private List<BizLiBgwm> bgwm;
	
	private List<BizLiZswm> zswm;
	
	private List<BizLiGyvm> gywm;
	
	
	
	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	public Long getTreatId() {
		return treatId;
	}
	public void setTreatId(Long treatId) {
		this.treatId = treatId;
	}
	
	@OneToOne  
    @JoinColumn(name="patientId",insertable=true,unique=true)
	public PatientDoc getPatient() {
		return patient;
	}
	public void setPatient(PatientDoc patient) {
		this.patient = patient;
	}
	public Integer getJieyan() {
		return jieyan;
	}
	public void setJieyan(Integer jieyan) {
		this.jieyan = jieyan;
	}
	public Integer getJiejiu() {
		return jiejiu;
	}
	public void setJiejiu(Integer jiejiu) {
		this.jiejiu = jiejiu;
	}
	public Integer getKztz() {
		return kztz;
	}
	public void setKztz(Integer kztz) {
		this.kztz = kztz;
	}
	public String getOther() {
		return other;
	}
	public void setOther(String other) {
		this.other = other;
	}
	public Integer getIsyg() {
		return isyg;
	}
	public void setIsyg(Integer isyg) {
		this.isyg = isyg;
	}
	public Integer getIsbg() {
		return isbg;
	}
	public void setIsbg(Integer isbg) {
		this.isbg = isbg;
	}
	public Integer getIszs() {
		return iszs;
	}
	public void setIszs(Integer iszs) {
		this.iszs = iszs;
	}
	@OneToMany(cascade=CascadeType.ALL,fetch=FetchType.LAZY,mappedBy="treathis")
	public List<BizLiYgwm> getYgwm() {
		return ygwm;
	}
	public void setYgwm(List<BizLiYgwm> ygwm) {
		this.ygwm = ygwm;
	}
	@OneToMany(cascade=CascadeType.ALL,fetch=FetchType.LAZY,mappedBy="treathis")
	public List<BizLiBgwm> getBgwm() {
		return bgwm;
	}
	public void setBgwm(List<BizLiBgwm> bgwm) {
		this.bgwm = bgwm;
	}
	@OneToMany(cascade=CascadeType.ALL,fetch=FetchType.LAZY,mappedBy="treathis")
	public List<BizLiZswm> getZswm() {
		return zswm;
	}
	public void setZswm(List<BizLiZswm> zswm) {
		this.zswm = zswm;
	}
	@OneToMany(cascade=CascadeType.ALL,fetch=FetchType.LAZY,mappedBy="treathis")
	public List<BizLiGyvm> getGywm() {
		return gywm;
	}
	public void setGywm(List<BizLiGyvm> gywm) {
		this.gywm = gywm;
	}
	
	

}
